package com.xjt.java.test;

import java.io.BufferedReader;
import java.util.Scanner;

import org.omg.CORBA.PUBLIC_MEMBER;

public class DiGui {

	/**
	 * @param args
	 */
	
	
	public static void main(String[] args) {
		 int inputnumber;
		 Scanner insScanner = new Scanner(System.in);
		System.out.println("please input a int number:");
		
		inputnumber=insScanner.nextInt();
		 int x=inputnumber;

		Sub(Increase(inputnumber));

	}

	public static int Increase(int num) {
		if(num<=5000)
		{
			System.out.println("----->"+num);
		    return num=Increase(2*num);
		}else{
			System.out.println("----->"+num);
			return num;
		}
		
	}
	public static int Sub(int num) {
	
		if(num>=1234)
		{
			System.out.println("----->"+num);
		    return num=Sub( num/2);
		}else{
			System.out.println("----->"+num);
			return num;
		}
		
	}
}
